package com.ncloud.product.mapper;

import java.util.List;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;

import com.ncloud.product.entity.DiscntCompItem;

@Mapper
public interface DiscntCompItemMapper {

	@Select("select * from bs_p_discnt_comp_item where comp_inst_id = #{compInstId} and eff_flag = '1'")
	@Results({ @Result(column = "comp_inst_id", property = "compInstId"),
			@Result(column = "attr_code", property = "attrCode"),
			@Result(column = "attr_value", property = "attrValue"), @Result(column = "eff_flag", property = "effFlag"),
			@Result(column = "create_time", property = "createTime"),
			@Result(column = "create_user", property = "createUser"),
			@Result(column = "update_time", property = "updateTime"),
			@Result(column = "update_user", property = "updateUser"), @Result(column = "remark", property = "remark") })
	List<DiscntCompItem> getCompItemByInstId(Long compInstId);

}
